package org.yuxizhou.weibo.plugin.weibo;

public class WeiboHtml {
	public static String HTML1 = "<html>";
	public static String HTML2 = "</html>";
	public static String HEAD1 = "<head>";
	public static String HEAD2 = "</head>";
	public static String BODY1 = "<body>";
	public static String BODY2 = "</body>";
	public static String JAVASCRIPT1 = "<script>";
	public static String JAVASCRIPT2 = "</script>";
	public static String JAVASCRIPT_NOTIFIER = "onmousedown=\"window.status=this.id; return true;\" onmouseup=\"window.status='';\"";
	//public static String JAVASCRIPT_NOTIFIER = "onclick=\"window.status=this.id; return true;\"";
	
	public static String getWelcomePage(){
		StringBuffer b = new StringBuffer();
		b.append(HTML1);
		b.append(HEAD1);
		b.append(JAVASCRIPT1);
		b.append(WeiboJavaScript.externalNotifier);
		b.append(JAVASCRIPT2);
		b.append(HEAD2);
		b.append(BODY1);
		b.append("<p>WELCOME</p>");
		b.append("<input type=\"text\" id=\"username\" />");
		b.append("<br />");
		b.append("<input type=\"text\" id=\"password\" />");
		b.append("<br />");
		//b.append("<input type=\"button\" value=\"SET\" id=\"login\" onclick=\"notifier()\"/>");
		b.append("<input type=\"button\" value=\"SET\" id=\"login\" "+JAVASCRIPT_NOTIFIER+"/>");
		b.append(BODY2);
		b.append(HTML2);
		return b.toString();
	}
}
